6eddfe9d32bc37349ab3bb6f3ee256bfd8fc1a83,vertx-circuit-breaker/src/main/java/examples/Examples.java,Examples,example1,#Vertx#,29

Before Change


            .setResetTimeout(10000) // time spent in open state before attempting to re-try
    );

    breaker.executeBlocking(v -> {
      // some code executing with the breaker
      // if this code fails, the breker increased the
      // number of failures
    });
  }

  public void example2(Vertx vertx) {

After Change


            .setResetTimeout(10000) // time spent in open state before attempting to re-try
    );

    breaker.execute(future -> {
      // some code executing with the breaker
      // the code reports failures or success on the given future.
      // if this future is marked as failed, the breaker increased the
      // number of failures
    }).setHandler(ar -> {
      // Get the operation result.
    });
  }

  public void example2(Vertx vertx) {